{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Convolution Layer"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "```{note}\n",
    "A neural network that use convolution layers is often called a CNN, a convolution neural network.\n",
    "```"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## What do convolution layers do?\n",
    "\n",
    "Taking image processing for example, a convolution layer compute the local features (whether there's an edge here, a dot there, etc), and aggregate the result into another image, which can sometimes be visualized.\n",
    "There are different kinds of convolution layers. We often use the 1-dimension version for text processing, 2-dimension version for image processing (most common)."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## When to use a convolution layer?\n",
    "\n",
    "Convolution layers are often used to directly process inputs, which means they are often places in the front of a model.\n",
    "Use of convolution in image processing is very common (usually paired with linear layers and pooling layers for classification). Convolution layers are also quite common in text processing."
   ]
  }
 ],
 "metadata": {
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": 3
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
